package com.wl.convert;

import java.io.File;

import static com.wl.common.WindowComponent.showAlert;

public class PdfToOfdConverter {

  public static void convertPdfToOfd(File pdfFile) {
//    String pdfPath = pdfFile.getAbsolutePath();
//    String docxPath = pdfPath.substring(0, pdfPath.lastIndexOf('.')) + ".docx";
//
//    try (PDDocument pdfDocument = PDDocument.load(pdfFile);
//         XWPFDocument docxDocument = new XWPFDocument()) {
//
//      PDFTextStripper pdfStripper = new PDFTextStripper();
//      String text = pdfStripper.getText(pdfDocument);
//
//      XWPFParagraph paragraph = docxDocument.createParagraph();
//      paragraph.createRun().setText(text);
//
//      try (FileOutputStream out = new FileOutputStream(new File(docxPath))) {
//        docxDocument.write(out);
//      }

    showAlert("哈哈哈该功能我没写！", "该功能我没写我不想写太难了。", "我晒干了沉默放弃了治疗~！");

//    } catch (IOException e) {
//      e.printStackTrace();
//    }
  }
}
